package com.pig4cloud.pig.customer.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.pig4cloud.pig.common.core.util.R;
import com.pig4cloud.pig.customer.vo.TrCustomer;

public interface CustomerService extends IService<TrCustomer> {
	//创建新增方法，用于实现手机号校验逻辑
	R addCustomer(TrCustomer customer);

	Page<TrCustomer>pageCustomers(Page<TrCustomer> page, TrCustomer trCustomer);

	TrCustomer getByIdWithCount(Long cusId);
	// 新增：检查手机号是否存在（支持修改时排除自身）
	R<Boolean> checkTelExists(String cusTel, Long cusId);

	R validateTel(TrCustomer customer, boolean b);
}
